package com.neusoft.tijiancms.mapper;

import com.neusoft.tijiancms.po.CiReport;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface CiReportMapper {

	/**
	 * 根据orderId查询体检报告
	 * @param orderId
	 * @return
	 */
	@Select("select count(*) from ciReport where orderId=#{orderId}")
	public int getCiReportByOrderId(Integer orderId);

	/**
	 * 批量添加体检报告
	 * @param list
	 * @return
	 */
	public int saveCiReport(List<CiReport> list);

	/**
	 * 根据orderId查询体检报告列表
	 * @param orderId
	 * @return
	 */
	@Select("select * from ciReport where orderId=#{orderId}")
	public List<CiReport> listCiReport(Integer orderId);
}
